package org.foreverframework.fileupload.web.action;

import java.io.File;

import org.apache.struts2.ServletActionContext;
import org.springframework.context.annotation.Scope;
import org.springframework.stereotype.Controller;

@Controller("fileAction")
@Scope("prototype")
public class FileAction {

	private File excel;
	private String excelFileName;

	public void upload() throws Exception {
		System.out.println(excelFileName);
		ServletActionContext.getResponse().getWriter().print("ok");
	}

	public File getExcel() {
		return excel;
	}

	public void setExcel(File excel) {
		this.excel = excel;
	}

	public String getExcelFileName() {
		return excelFileName;
	}

	public void setExcelFileName(String excelFileName) {
		this.excelFileName = excelFileName;
	}

}
